package com.xxgc.qinglian.qinglianserver.entity;/*
 * @Author:lsx
 * @Date:2025/6/1--06--01--11:35
 *
 */

import com.baomidou.mybatisplus.annotation.IdType;
import lombok.Data;
import org.dromara.autotable.annotation.ColumnComment;
import org.dromara.autotable.annotation.mysql.MysqlTypeConstant;
import org.dromara.mpe.autotable.annotation.Column;
import org.dromara.mpe.autotable.annotation.ColumnId;
import org.dromara.mpe.autotable.annotation.Table;
import org.dromara.mpe.processer.annotation.AutoDefine;
import org.dromara.mpe.processer.annotation.AutoMapper;
import org.dromara.mpe.processer.annotation.AutoRepository;

import java.time.LocalDateTime;

@AutoDefine
@AutoMapper
@AutoRepository
@Data
@Table(value = "qinglian_user", comment = "用户表")
public class UserEntity {
    @ColumnComment("用户ID")
    @ColumnId(mode = IdType.AUTO, comment = "用户主键", type = MysqlTypeConstant.BIGINT, length = 32)
    private String userId;

    @ColumnComment("用户名，唯一标识")
    private String username;

    @ColumnComment("密码")
    private String password;

    @ColumnComment("用户昵称")
    private String nickname;

    @ColumnComment("手机号")
    private String phone;

    @ColumnComment("头像URL")
    private String avatar;

    @ColumnComment("用户类型：0-场外，1-场内，2-管理员（场控）")
    private Integer userType;

    @ColumnComment("创建时间")
    @Column(comment = "创建时间", type = MysqlTypeConstant.DATETIME)
    private LocalDateTime createTime;

    @ColumnComment("用户状态：0-禁用，1-正常")
    private Integer status;
}

